#ifndef LED_GEN
#define LED_GEN

/* Generic led handling macros */

#include <util/delay.h> 

/** PORT DEFINITIONS **/
#define LED1_SET_DDR DDRC|=1<<PC5
#define LED1_ON      PORTC|=1<<PC5
#define LED1_OFF     PORTC&=~(1<<PC5)
/** END OF PORT DEFINITIONS **/

/** INITIALIZES LED **/
#define LED1_INIT    \
  { LED1_SET_DDR;    \
    LED1_OFF; }

/** MACRO FOR LED BLINKING IN BUSY WAIT **/
#define LED1_BLINK(t_out_ms) \
  { LED1_ON;		     \
    _delay_ms(t_out_ms);     \
    LED1_OFF;		     \
    _delay_ms(t_out_ms);}


#endif /*LED_GEN*/
